/**
 * Copyright (c) 2016-2019 九点科技 All rights reserved.
 *
 * http://www.9dyun.cn
 *
 * 版权所有，侵权必究！
 */
package com.dian.modules.sale.entity;

import com.dian.common.validator.group.AddGroup;
import com.dian.common.validator.group.UpdateGroup;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import java.math.BigDecimal;
import com.dian.common.entity.BaseEntity;
import java.util.Date;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import org.hibernate.validator.constraints.Length;
import com.fasterxml.jackson.annotation.JsonFormat;
/**
 * 量尺单
 *
 * @author xiaolai
 * @email xiaolai@9dyun.cn
 * @date 2019-06-21 10:19:58
 */
@Data
@TableName("sale_gauge_sheet")
public class GaugeSheetEntity extends BaseEntity {
    private static final long serialVersionUID = 1L;

        /**
        * 预订单id;来源于sale_prob_head.id
        */
        @NotNull(message="预订单id不能为空",groups = {AddGroup.class,UpdateGroup.class})
        private Long probId;

        /**
        * 预订单编码;来源于sale_prob_head.prob_no
        */
        @Length(max=20,  groups ={AddGroup.class, UpdateGroup.class}, message="预订单编码长度不能超过20个字符")
        private String probNo;



        /**
        * 量尺日期;format:yyyy-MM-dd
        */
        @JsonFormat( pattern="yyyy-MM-dd")
        @NotNull(message="量尺日期不能为空",groups = {AddGroup.class,UpdateGroup.class})
        private Date gaugeDate;



        /**
        * 预约日期;format:yyyy-MM-dd
        */
        @JsonFormat( pattern="yyyy-MM-dd")
        @NotNull(message="预约日期不能为空",groups = {AddGroup.class,UpdateGroup.class})
        private Date estDate;



        /**
        * 安装方式
        */
        @NotBlank(message="安装方式不能为空",  groups ={AddGroup.class, UpdateGroup.class})
        @Length(max=100,  groups ={AddGroup.class, UpdateGroup.class}, message="安装方式长度不能超过100个字符")
        private String instalModel;



        /**
        * 量尺面积
        */
        @NotNull(message="量尺面积不能为空",groups = {AddGroup.class,UpdateGroup.class})
        private BigDecimal area;



        /**
        * 水平情况
        */
        @NotBlank(message="水平情况不能为空",  groups ={AddGroup.class, UpdateGroup.class})
        @Length(max=100,  groups ={AddGroup.class, UpdateGroup.class}, message="水平情况长度不能超过100个字符")
        private String level;



        /**
        * 订单状态:1-未审核-WAITCHECK;2-已审核-AUDITED-;99-已作废-INVALID
        */
        private Integer gaugeState;






}
